package pe.com.bn.sach.domain;

/**
 * Bnchf22DestModalidadId entity.
 * 
 * @author MyEclipse Persistence Tools
 */

public class Bnchf22DestModalidadId implements java.io.Serializable {

	// Fields

	private Bnchf18Destino bnchf18Destino;
	private Bnchf19Modalidad bnchf19Modalidad;

	// Constructors

	/** default constructor */
	public Bnchf22DestModalidadId() {
		 bnchf18Destino=new Bnchf18Destino();
		bnchf19Modalidad=new Bnchf19Modalidad ();		
	}

	/** full constructor */
	public Bnchf22DestModalidadId(Bnchf18Destino bnchf18Destino,
			Bnchf19Modalidad bnchf19Modalidad) {
		this.bnchf18Destino = bnchf18Destino;
		this.bnchf19Modalidad = bnchf19Modalidad;
	}

	// Property accessors

	public Bnchf18Destino getBnchf18Destino() {
		return this.bnchf18Destino;
	}

	public void setBnchf18Destino(Bnchf18Destino bnchf18Destino) {
		this.bnchf18Destino = bnchf18Destino;
	}

	public Bnchf19Modalidad getBnchf19Modalidad() {
		return this.bnchf19Modalidad;
	}

	public void setBnchf19Modalidad(Bnchf19Modalidad bnchf19Modalidad) {
		this.bnchf19Modalidad = bnchf19Modalidad;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof Bnchf22DestModalidadId))
			return false;
		Bnchf22DestModalidadId castOther = (Bnchf22DestModalidadId) other;

		return ((this.getBnchf18Destino() == castOther.getBnchf18Destino()) || (this
				.getBnchf18Destino() != null
				&& castOther.getBnchf18Destino() != null && this
				.getBnchf18Destino().equals(castOther.getBnchf18Destino())))
				&& ((this.getBnchf19Modalidad() == castOther
						.getBnchf19Modalidad()) || (this.getBnchf19Modalidad() != null
						&& castOther.getBnchf19Modalidad() != null && this
						.getBnchf19Modalidad().equals(
								castOther.getBnchf19Modalidad())));
	}

	public int hashCode() {
		int result = 17;

		result = 37
				* result
				+ (getBnchf18Destino() == null ? 0 : this.getBnchf18Destino()
						.hashCode());
		result = 37
				* result
				+ (getBnchf19Modalidad() == null ? 0 : this
						.getBnchf19Modalidad().hashCode());
		return result;
	}

}